<%--
 - Copyright (c) 2009-2011 ETCORE Labs. All rights reserved. 
 - 
 - This software is the confidential and proprietary information of ETCORE Labs. 
 - You shall not disclose such confidential information and shall use it only
 - in accordance with the terms of the license agreement you entered into
 - with ETCORE Labs.
 -
 - Support can be obtained from support forums at:
 - http://www.etcore.com/
 -
 - @author: ETCORE GroupTalk developers
 -
 --%>
<%@ page contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
<%@ taglib uri="http://jakarta.apache.org/taglibs/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib uri="http://www.etcore.com/grouptalk" prefix="grouptalk"%>


<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title><c:out value='${messageDetail.name}' />-<c:out
	value='${context.title}' /></title>
<link rel="stylesheet" href="/group/css/styles.css" type="text/css">
<script>
 
var width=window.screen.width;
 
var n=10;
if(width>=1600){
n=12;
 
}else if(width<=800){
n=8;
 	
}
  
function   doImgOnload(img){ 
        var   maxWidth=600;  
        if(   img.width   > maxWidth   ){ 
                img.width=maxWidth; 
        } 
       
} 
 

function getTextWidth(){
 
	 
	var textWidth=600;
	if(width>=1600){
		textWidth=1100;
	 
	}else if(width>=1200){
		textWidth=850;;
	 	
	}else if(width>=1000){
		textWidth=750;;
	 	
	}
	return textWidth;
}
function setTextWidth(){
 var table=document.getElementById("messageContentTable"); 
 table.style.width=getTextWidth();
}
 

 

</script>
<script type="text/javascript"
	src="/group/ui-component/textarea/js/textviewer.js"></script>
<script language="javascript">
function checkForm1()
{

if(form1.content.value==""||form1.content.value.replace(/(^\s*)|(\s*$)/g, "")=="")
{
alert("<c:out value='${context.msg_content_null}'/>");
form1.content.focus();
return false;
}
if(form1.content.length>15000)
{
alert("<c:out value='${context.msg_content_null}'/>");
form1.content.focus();
return false;
}


return true;
}
function checkForm2()
{

if(form2.name.value==""||form2.name.value.replace(/(^\s*)|(\s*$)/g, "")=="")
{
alert("<c:out value='${context.msg_title_null}'/>");
form2.name.focus();
return false;
}
return true;
}
</script>
</head>

<body bottomMargin=0 leftMargin=10 topMargin=0 rightMargin=10
	rightMargin=10 marginheight="0">

<c:import url="/group/ui-component/divdialog/divdialog.html" />

<table width=100% border="0" cellpadding="0" cellspacing="0"
	align=center>

	<tr>
		<td width=100%>
		<div><c:import url="/banner.jsp?currentPlatform=${group.open}" />
		</div>
		</td>
	</tr>
	<tr>
		<td width=100%>
		<table width=100% cellpadding="0" cellspacing="0">
			<tr>

				<td width=100% valign=top><c:set var="platform"
					value="platform${group.open}" /> <c:set var="platformLabel"
					value="${context[platform]}" /> <c:set var="currentViewer"
					value="groupadmin" /> <c:set var="posturl" value="" /> <c:set
					var="encryptedUrl" value="" /> <c:if test="${group.open==3 }">
					<c:set var="currentViewer" value="bookmarks" />
				</c:if> <c:if test="${group.open==1 }">
					<c:set var="currentViewer" value="news" />
					<c:set var="posturl" value="?nav=${group.nav }" />
					<c:if test="${group.nav==1 }">
						<c:set var="platformLabel" value="${context.nav1}" />
					</c:if>
				</c:if> <c:if test="${group.open==2 }">
					<c:set var="currentViewer" value="community" />
					<c:if test="${group.nav==1 }">
						<c:set var="platformLabel" value="${context.nav2}" />
					</c:if>
					<c:set var="posturl" value="?nav=${group.nav }" />
				</c:if> <c:if test="${group.open==4 }">
					<c:set var="currentViewer" value="reminders" />
				</c:if> <c:if test="${group.open==0 }">
					<c:set var="posturl" value="?open=0" />
				</c:if>
				<table width=100% cellpadding="0" cellspacing="0">




					<TR>

						<TD valign=top width=100%>




						<table>
							<tr>
								<td style="margin-left: 15px; color: #808080"><a href="/"
									style="color: #3B5998">${context.homepage }</a> -> <a
									href="/group/${currentViewer }${context.postfix}${posturl}"
									style="color: #3B5998">${platformLabel }</a><c:if
									test="${group.open!=4 }"> -> <a style="color: #3B5998"
										href="/group/${page}${context.postfix}?id=${group.id}&gid=${group.id}">${group.name
									}</a>
								</c:if></td>
							</tr>


						</table>

						<table id=messageContentTable width=100%
							style="border: 1px solid #d4d2d4;" cellpadding="0"
							cellspacing="0" align=center>



							<tr>
								<td colspan=3 align=center
									style="font-size: 18px; height: 35px;"><b><c:out
									value='${messageDetail.name}' /><c:if test="${group.open==4}">&nbsp;<c:out
										value='${reminderDate}' />
								</c:if></b></td>

							</tr>
							<tr>
								<td colspan=3 style="color: #808080; font-size: 12px;"
									align=center nowrap><a
									href="/group/viewUser<c:out value='${context.postfix }' />?targetUserName=<c:out
									value='${messageDetail.userName}' />"><font
									color=#808080><c:out value='${messageDetail.userName}' /></font></a>&nbsp;
								<c:out value='${messageDetail.addtime}' /> &nbsp; <c:if
									test="${group.open==3 }">

									<a
										href="<c:if test="${!(fn:startsWith(messageDetail.source,'http'))}">http://${messageDetail.source}</c:if><c:if test="${(fn:startsWith(messageDetail.source,'http'))}">${messageDetail.source}</c:if>"><font
										color=green><c:out value='${messageDetail.source}' /></font></a>&nbsp; </c:if></td>

							</tr>





							<c:set var="rank" value="1" />
							<c:forEach var="attachment" items="${attachments }">
								<tr bgcolor="#ffffff">
									<td colspan=3 align=center
										style="border-bottom: 1px solid #d2d4d2; color: #999999">
									<c:choose>
										<c:when
											test="${fn:endsWith(attachment.attached,'JPG')||fn:endsWith(attachment.attached,'jpg')||fn:endsWith(attachment.attached,'GIF')||fn:endsWith(attachment.attached,'gif')||fn:endsWith(attachment.attached,'BMP')||fn:endsWith(attachment.attached,'bmp')}">
											<c:out value='${attachment.name}' />
											<br />
											<c:if test="${group.open==3 }">
												<a
													href="<c:if test="${!(fn:startsWith(messageDetail.source,'http'))}">http://${messageDetail.source}</c:if><c:if test="${(fn:startsWith(messageDetail.source,'http'))}">${messageDetail.source}</c:if>"><img
												src="${attachment.attached }" onload= "doImgOnload(this); "
												  /></a>
											</c:if>
											<c:if test="${group.open!=3 }">
												<a href="<c:out value='${attachment.attached}' />"
													target=_blank><img src="${attachment.attached }" onload= "doImgOnload(this); "
													   /></a>
											</c:if>
 

										</c:when>
										<c:when test="${fn:endsWith(attachment.attached,'.swf')}">
											<c:out value='${attachment.name}' />
											<br />
											<embed src="<c:out value='${attachment.attached}' />"
												width="750" height="570" loop="0" quality="high"
												pluginspage="http://www.adobe.com/go/getflashplayer"
												type="application/x-shockwave-flash" menu="false">
											</embed>

										</c:when>
										<c:otherwise>
											<a style="color: #999999"
												href="<c:out value='${attachment.attached}' />"
												target=_blank><c:out value='${attachment.name}' /></a>
										</c:otherwise>
									</c:choose> <c:if
										test='${isAdmin ||(not empty session_user && session_user.userName eq messageDetail.userName) }'>
										<br />
										<table>
											<tr>

												<td>
												<form
													action="/group/messagedetail<c:out value='${context.postfix}'/>"><input
													type=hidden name="id"
													value="<c:out value='${messageDetail.id}' />"> <input
													type=hidden name="cmd" value="sortAttachments"> <input
													type=hidden name="sourceRankv"
													value="<c:out value='${rank}' />"> <select
													name=rankv onChange="this.form.submit();">
													<c:set var="count" value="1" />
													<c:forEach begin="1" end="${attachmentSize}" step="1">

														<option value="<c:out value='${count }' />"
															<c:if test="${count==rank }"> selected </c:if>><c:out
															value='${count }' /></option>
														<c:set var="count" value="${count+1 }" />
													</c:forEach>
												</select></form>
												</td>
												<td>
												<form method=post
													action="/group/messagedetail<c:out value='${context.postfix}'/>"><input
													type=hidden name="id"
													value="<c:out value='${messageDetail.id}' />"> <input
													type=hidden name="cmd" value="editAtt"> <input
													type=hidden name="aid"
													value="<c:out value='${attachment.id}' />"> <input
													type=text value='${attachment.name }' size=12 name=name />
												<input type=submit value="${context.edit }" /></form>
												</td>
												<td><a
													href="/group/messagedetail<c:out value='${context.postfix}'/>?op=delAtt&id=<c:out value='${messageDetail.id}' />&aid=<c:out value='${attachment.id}' />"
													onclick='if(window.confirm("<c:out value='${context.msg_del_now}' />")){return true;}else{return false;}'><img
													src="/group/images/button_delete.gif" valign=bottom
													width="17" height="17"
													alt="<c:out value='${context.text_del}' />..." border="0"></a></td>
										</table>


									</c:if> <br />

									</td>
								</tr>
								<c:set var="rank" value="${rank+1 }" />
							</c:forEach>


							<tr bgcolor="#ffffff">

								<td colspan=3><c:import
									url="/group/messagedetail_content.jsp" /></TD>
							</TR>

							<tr>
								<td align=left width=100% colspan=3
									style="border-top: solid 1px #d2d4d2;">
								<table width=100% style="left: 5px">
									<tr>
										<td align=left nowrap
											style="color: #808080; font-size: 13px; height: 30px;">
										${context.text_click}(${messageDetail.num}) |
										${context.text_comment}(${all })</td>
										<td width=100% align=center><c:if
											test='${ empty session_user }'>
											<input type=button onclick="showLoginWin();"
												style="border: 1px solid #36518B; cursor: pointer; height: 25px; font-size: 16px; color: #36518B; background: #ffffff;"
												value="<c:out
												value='${context.text_reply}' />">
										</c:if><c:if test='${ not empty session_user }'>
											<input type=button onclick="form1.content.focus();"
												style="border: 1px solid #36518B; cursor: pointer; height: 25px; font-size: 16px; color: #36518B; background: #ffffff;"
												value="<c:out
												value='${context.text_reply}' />">
										</c:if></td>
										<td nowrap align=right><c:set var="pid"
											value="${startpid }" /> <c:forEach begin="${startpid }"
											end="${endpid }" step="1">
											<c:if test="${!(context.msg_encryptedUrl) }">
												<c:set var="url"
													value="/group/messagedetail${context.postfix}?pageid=${pid}&id=${param.id}" />

												<a
													<c:if test='${intpageid==pid }'> style="font-weight:bold;color:red;"</c:if>
													href="${url }">[<c:out value='${pid}' />]</a>
											</c:if>
											<c:if test="${(context.msg_encryptedUrl) }">
												<c:set var='urlFragmentStr'
													value="?pageid=${pid}&id=${param.id}" />

												<c:set var='urlFragment'
													value='${grouptalk:getEncryptedStr(urlFragmentStr)}' />
												<a
													<c:if test='${intpageid==pid }'> style="font-weight:bold;color:red;" </c:if>
													href="/group/messagedetail<c:out value='${context.postfix}' />/~<c:out value='${urlFragment }' />">[<c:out
													value='${pid}' />]</a>
											</c:if>
											<c:set var="pid" value="${pid+1 }" />
&nbsp;&nbsp;</c:forEach> <c:if test="${intpageid>1 }">
											<c:if test="${!(context.msg_encryptedUrl) }">
												<c:set var="url"
													value="/group/messagedetail${context.postfix}?pageid=${intpageid-1}&id=${param.id}" />

												<a href="${url }"> [<c:out
													value='${context.previous_page}' />] </a>
											</c:if>
											<c:if test="${(context.msg_encryptedUrl) }">
												<c:set var='urlFragmentStr'
													value="?pageid=${intpageid-1}&id=${param.id}" />

												<c:set var='urlFragment'
													value='${grouptalk:getEncryptedStr(urlFragmentStr)}' />
												<a
													href="/group/messagedetail<c:out value='${context.postfix}' />/~<c:out value='${urlFragment }' />">
												[<c:out value='${context.previous_page}' />] </a>
											</c:if>
&nbsp;
</c:if> <c:if test="${intpageid<pagenums }">
											<c:if test="${!(context.msg_encryptedUrl) }">
												<c:set var="url"
													value="/group/messagedetail${context.postfix}?pageid=${intpageid+1}&id=${param.id}" />
												<a href="${url }"> [<c:out value='${context.next_page}' />]
												</a>
											</c:if>
											<c:if test="${(context.msg_encryptedUrl) }">
												<c:set var='urlFragmentStr'
													value="?pageid=${intpageid+1}&id=${param.id}" />

												<c:set var='urlFragment'
													value='${grouptalk:getEncryptedStr(urlFragmentStr)}' />
												<a
													href="/group/messagedetail<c:out value='${context.postfix}' />/~<c:out value='${urlFragment }' />">
												[<c:out value='${context.next_page}' />] </a>
											</c:if>
&nbsp;
</c:if></td>

										<c:if test='${(not empty session_user)&& (!included) }'>
											<td align=center>
											<form method=post
												action="/group/messagedetail<c:out value='${context.postfix }' />">
											<input type=hidden name=cmd value="addFavourite"><input
												type=hidden name=id
												value="<c:out value='${messageDetail.id}' />"><input
												type=submit
												style="border: 1px solid #36518B; cursor: pointer; height: 20px; font-size: 13px; color: #36518B; background: #ffffff;"
												value="<c:out value='${context.text_include }' />" /></form>
											</td>
										</c:if>
										<c:if
											test='${isAdmin ||(not empty session_user && session_user.userName eq messageDetail.userName) }'>
											<c:set var="editControl" value='editMessage' />
											<c:if test='${group.open==3}'>
												<c:set var="editControl" value='editBookmark' />
											</c:if>
											<td align=right><input type=button
												onclick="location='/group/<c:out value='${editControl}' /><c:out value='${context.postfix}' />?id=<c:out value='${param.id }' />';"
												style="border: 1px solid #36518B; cursor: pointer; height: 20px; font-size: 13px; color: #36518B; background: #ffffff;"
												value="<c:out
												value='${context.edit}' />"></td>


											<td align=right><input type=button
												onclick="showDivControl('localAttachmentControl',500,180)"
												style="border: 1px solid #36518B; cursor: pointer; height: 20px; font-size: 13px; color: #36518B; background: #ffffff;"
												value="<c:out value='${context.local_attachment}' />">

											</td>
											<td align=right><input type=button
												onclick="showDivControl('remoteAttachmentControl',500,178)"
												style="border: 1px solid #36518B; cursor: pointer; height: 20px; font-size: 13px; color: #36518B; background: #ffffff;"
												value="<c:out value='${context.remote_attachment}' />">

											</td>
										</c:if>
										<c:if test='${isAdmin }'>
											<td align=right><input type=button
												onclick="showDivControl('shareControl',500,90)"
												style="border: 1px solid #36518B; cursor: pointer; height: 20px; font-size: 13px; color: #36518B; background: #ffffff;"
												value="<c:out value='${context.text_share}' />"></td>
										</c:if>

									</tr>
								</table>
								</td>
							</tr>






							<c:set var="commentCount" value="1" />
							<c:forEach var="comment" items="${comments }">
								<c:set var="toUserAvatar" value="${comment.userName}_avatar" />
								<c:url value="viewUser${context.postfix}" var="toUserUrl">
									<c:param name="targetUserName" value="${comment.userName }" />
								</c:url>
								<tr bgcolor=#EDF3E4>
									<td valign=top align=center><a
										style="font-size: 12px; color: #005EAC"
										href="/group/${toUserUrl }"><c:if
										test="${not empty requestScope[toUserAvatar]&&fn:indexOf(requestScope[toUserAvatar],'upload')!=-1 }">
										<img src="${requestScope[toUserAvatar]}"
											style="margin-left: 5px; margin-right: 5px;" width=26
											border=0 />
									</c:if><c:if
										test="${empty requestScope[toUserAvatar]||fn:indexOf(requestScope[toUserAvatar],'upload')==-1 }">
										<img src="/group/images/avatar/avatar.jpg"
											style="margin-left: 5px; margin-right: 5px;" width=26
											border=0 />
									</c:if></a></td>
									<td valign=top height=45 align=left nowrap
										style="font-size: 12px; color: #808080"><a
										style="font-size: 12px; color: #005EAC"
										href="/group/${toUserUrl }"><c:out
										value="${comment.userName }" /></a>&nbsp; <c:out
										value="${comment.time }" />&nbsp;<c:out
										value="${context.text_reply }" />：<br />
									<c:out value='${comment.content }' escapeXml="false" /></td>

									<td align=right width=100% style="color: #808080"><c:out
										value="${commentCount}" /><c:set var="commentCount"
										value="${commentCount+1 }" /> <c:if
										test="${isAdmin||comment.userName eq session_user.userName }">
										<a
											href="/group/messagedetail<c:out value='${context.postfix }' />?cmd=delGcomment&commentId=<c:out value='${comment.id }' />&id=<c:out value='${param.id }' />"
											onclick='if(window.confirm("<c:out value='${context.msg_del_now }' />")){return true;}else{return false;}'><img
											src="/group/images/button_delete.gif" valign=bottom
											width="17" height="17"
											alt="<c:out value='${context.text_del }' />..." border="0"></a>
									</c:if></td>
								</tr>

								<tr>
									<td colspan=3>&nbsp;</td>
								</tr>
							</c:forEach>



							<tr bgcolor="#ffffff">
								<td align=right height=45 colspan=2></td>
								<td align=right><c:set var="pid" value="${startpid }" /> <c:forEach
									begin="${startpid }" end="${endpid }" step="1">
									<c:if test="${!(context.msg_encryptedUrl) }">
										<c:set var="url"
											value="/group/messagedetail${context.postfix}?pageid=${pid}&id=${param.id}" />

										<a
											<c:if test='${intpageid==pid }'> style="font-weight:bold;color:red;"</c:if>
											href="${url }">[<c:out value='${pid}' />]</a>
									</c:if>
									<c:if test="${(context.msg_encryptedUrl) }">
										<c:set var='urlFragmentStr'
											value="?pageid=${pid}&id=${param.id}" />

										<c:set var='urlFragment'
											value='${grouptalk:getEncryptedStr(urlFragmentStr)}' />
										<a
											<c:if test='${intpageid==pid }'> style="font-weight:bold;color:red;" </c:if>
											href="/group/messagedetail<c:out value='${context.postfix}' />/~<c:out value='${urlFragment }' />">[<c:out
											value='${pid}' />]</a>
									</c:if>
									<c:set var="pid" value="${pid+1 }" />
&nbsp;&nbsp;</c:forEach> <c:if test="${intpageid>1 }">
									<c:if test="${!(context.msg_encryptedUrl) }">
										<c:set var="url"
											value="/group/messagedetail${context.postfix}?pageid=${intpageid-1}&id=${param.id}" />

										<a href="${url }"> [<c:out
											value='${context.previous_page}' />] </a>
									</c:if>
									<c:if test="${(context.msg_encryptedUrl) }">
										<c:set var='urlFragmentStr'
											value="?pageid=${intpageid-1}&id=${param.id}" />

										<c:set var='urlFragment'
											value='${grouptalk:getEncryptedStr(urlFragmentStr)}' />
										<a
											href="/group/messagedetail<c:out value='${context.postfix}' />/~<c:out value='${urlFragment }' />">
										[<c:out value='${context.previous_page}' />] </a>
									</c:if>
&nbsp;
</c:if> <c:if test="${intpageid<pagenums }">
									<c:if test="${!(context.msg_encryptedUrl) }">
										<c:set var="url"
											value="/group/messagedetail${context.postfix}?pageid=${intpageid+1}&id=${param.id}" />
										<a href="${url }"> [<c:out value='${context.next_page}' />]
										</a>
									</c:if>
									<c:if test="${(context.msg_encryptedUrl) }">
										<c:set var='urlFragmentStr'
											value="?pageid=${intpageid+1}&id=${param.id}" />

										<c:set var='urlFragment'
											value='${grouptalk:getEncryptedStr(urlFragmentStr)}' />
										<a
											href="/group/messagedetail<c:out value='${context.postfix}' />/~<c:out value='${urlFragment }' />">
										[<c:out value='${context.next_page}' />] </a>
									</c:if>
&nbsp;
</c:if></td>
							</tr>


							<c:if test="${isAdmin}">
								<tr bgcolor="#E3EEFB">
									<td colspan=3 style="font-weight: 12px; color: #808080">
									<form method=post
										action="/group/messagedetail<c:out value='${context.postfix }' />">
									<input type=hidden name=cmd value="assignComments"> <input
										type=hidden name=id
										value="<c:out value='${messageDetail.id}' />">
									&nbsp;${context.hidden_comments}:${hiddenCommentsSize}&nbsp;<input
										type=submit style="cursor: pointer;"
										value="<c:out value='${context.auto_assign}' />"></form>
									</td>
								</tr>
							</c:if>
							<c:if
								test="${((not empty session_user) && group.open>=1) ||isAdmin }">
								<tr>
									<td colspan=3 align=center>
									<div id=commentControl
										style="display: block; valign: center; padding: 0px; background-color: white; z-index: 1002; overflow: hidden;">
									<form name="form1" onSubmit="return checkForm1();" method=post
										action="/group/messagedetail<c:out value='${context.postfix }' />">
									<input type=hidden name=cmd value="addGcomment"> <input
										type=hidden name=id
										value="<c:out value='${messageDetail.id}' />">
									<table width=500 cellspacing=0 cellpadding=0 border=0>


										<c:if test="${isAdmin}">
											<tr>
												<td><select name=flag>
													<option value='0' selected>${context.text_public }</option>
													<option value='-1'>${context.text_hidden}</option>
												</select></td>
												<td></td>
											</tr>
										</c:if>
										<tr bgcolor="#f8f8f8">

											<td valign=top width=40 align=center><c:if
												test="${not empty session_user.avatar&&fn:indexOf(session_user.avatar,'upload')!=-1 }">
												<img src="${session_user.avatar}"
													style="margin-left: 5px; margin-right: 5px;" width=26
													border=0 />
											</c:if><c:if
												test="${empty session_user.avatar||fn:indexOf(session_user.avatar,'upload')==-1 }">
												<img src="/group/images/avatar/avatar.jpg"
													style="margin-left: 5px; margin-right: 5px;" width=26
													border=0 />
											</c:if></td>
											<TD width=100%><textarea id="tests2" name="content"
												cols="50" rows="7 "></textarea></TD>
										</TR>

										<tr bgcolor="#f8f8f8">

											<TD align=center colspan=2><input type=submit
												style="cursor: pointer;"
												value="<c:out value='${context.text_comment}'/>"></TD>
										</TR>


									</table>
									</form>

									</div>
									</td>
								</tr>
							</c:if>


							<tr>
								<td colspan=3 width=100%><c:if
									test='${isAdmin ||(not empty session_user && session_user.userName eq messageDetail.userName) }'>
									<div id=localAttachmentControl
										style="display: none; valign: center; position: absolute; top: 20%; left: 30%; width: 550px; padding: 0px; border: 1px solid orange; background-color: white; z-index: 1002; overflow: hidden;">
									<table cellpadding="0" cellspacing="0" border="0" width="100%"
										align=center>
										<tr bgcolor="orange">
											<td width=100% style="height: 20px"><img
												src="/group/images/winlogo.gif" border=0 />&nbsp;<b><c:out
												value='${context.local_attachment}' /></b></td>
											<td width=25 align=right><img
												src="/group/images/close.gif"
												onClick="hideDivControl('localAttachmentControl')"
												style="cursor: pointer" border=0 /></td>
										</tr>
										<tr>
											<td colspan=3 width=100%>
											<FORM name="form2" enctype="multipart/form-data"
												onSubmit="return checkForm2();" method=post
												action="/group/messagedetail<c:out value='${context.postfix}' />?cmd=addAtt&id=${messageDetail.id}">
											<input type=hidden name=id
												value="<c:out value='${messageDetail.id}'/>">
											<table cellspacing=0 cellpadding=0 border=0 width=100%
												align=center>

												<tr>
													<td align=center colspan=3>${context.local_attachment}</td>
												</tr>
												<tr bgcolor="#ffffff">
													<td style="width: 100px;"><c:out
														value='${context.msg_title}' /></TD>
													<TD><input type=text name="name" size=50 maxlength=200></TD>
												</TR>
												<tr bgcolor="#ffffff">
													<td style="width: 100px;"><c:out
														value='${context.text_attached}' /></TD>
													<TD><input name="attached" type=file size="50"
														maxlength="500"></TD>
												</TR>

												<tr>
													<td align="center" colspan=3 style="height: 30px;"><input
														type="submit" style="cursor: pointer"
														value="<c:out value='${context.button_ok} '/>">&nbsp;&nbsp;<input
														type=button
														onclick="hideDivControl('localAttachmentControl')"
														style="cursor: pointer"
														value="<c:out value='${context.button_cancel}' />"></td>
												</tr>
											</table>
											</FORM>
											</td>
										</tr>
									</table>
									</div>
									<div id=remoteAttachmentControl
										style="display: none; valign: center; position: absolute; top: 20%; left: 30%; width: 550px; padding: 0px; border: 1px solid orange; background-color: white; z-index: 1002; overflow: hidden;">
									<table cellpadding="0" cellspacing="0" border="0" width="100%"
										align=center>
										<tr bgcolor="orange">
											<td width=100% style="height: 20px"><img
												src="/group/images/winlogo.gif" border=0 />&nbsp;<b><c:out
												value='${context.remote_attachment}' /></b></td>
											<td width=25 align=right><img
												src="/group/images/close.gif"
												onClick="hideDivControl('remoteAttachmentControl')"
												style="cursor: pointer" border=0 /></td>
										</tr>



										<tr>
											<td colspan=3 width=100%>

											<form name=form3 method=post
												action="/group/messagedetail<c:out value='${context.postfix}'/>">
											<input type=hidden name=id
												value="<c:out value='${messageDetail.id}'/>"> <input
												type=hidden name="urlLink" value="true">
											<table cellspacing=0 cellpadding=0 border=0 width=100%
												align=center>
												<tr>
													<td colspan=3 align=center>${context.remote_attachment}</td>
												</tr>


												<tr>
													<TD style="width: 100px;"><c:out
														value='${context.msg_title}' />:</td>
													<td><input type=text name="att_name" size=50
														maxlength=200></TD>
												</TR>
												<tr>
													<td style="width: 100px;">${context.remote_attachment}(URL):</td>
													<td><input type=text name="url" size=50 maxlength=300></td>
												</tr>
												<tr>
													<td align="center" colspan=3 style="height: 30px;"><input
														type="submit" style="cursor: pointer"
														value="<c:out value='${context.button_ok} '/>">&nbsp;&nbsp;<input
														type=button
														onclick="hideDivControl('remoteAttachmentControl')"
														style="cursor: pointer"
														value="<c:out value='${context.button_cancel}' />"></td>
												</tr>

											</table>
											</form>



											</td>
										</tr>





									</table>
									</div>
								</c:if>
								<div id=shareControl
									style="display: none; valign: center; position: absolute; top: 20%; left: 30%; width: 550px; padding: 0px; border: 1px solid orange; background-color: white; z-index: 1002; overflow: hidden;">
								<table cellpadding="0" cellspacing="0" border="0" width="100%"
									align=center>
									<tr bgcolor="orange">
										<td width=100% style="height: 20px"><img
											src="/group/images/winlogo.gif" border=0 />&nbsp;<b><c:out
											value='${context.text_share}' /></b></td>
										<td width=25 align=right><img
											src="/group/images/close.gif"
											onClick="hideDivControl('shareControl',500,90)"
											style="cursor: pointer;" border=0 /></td>
									</tr>
									<tr>
										<td colspan=3 width=100%>
										<FORM name="form3" onSubmit="return checkForm3();" method=post
											action="/group/messagedetail<c:out value='${context.postfix}' />?cmd=share">
										<input type=hidden name=id
											value="<c:out value='${messageDetail.id}'/>">
										<table cellspacing=0 cellpadding=0 border=0 width=100%
											align=center>

											<tr>
												<td align=center colspan=3><c:out
													value='${context.text_share }' /></td>
											</tr>
											<tr>
												<td style="width: 100px;"><c:out
													value='${context.text_user_name}' /></TD>
												<TD><input type=text name="userNames" size=60
													<c:if test="${not empty admins }">value='${admins }'</c:if>
													maxlength=300></TD>
											</TR>
											<tr>
												<td style="width: 100px;"><c:out
													value='${context.text_user_receiver}' /> Email</TD>
												<TD><input type=text name="userEmails" size=60
													maxlength=500></TD>
											</TR>


											<tr>
												<td align="center" colspan=3 style="height: 30px;"><input
													type="submit" style="cursor: pointer"
													value="<c:out value='${context.button_ok} '/>">&nbsp;&nbsp;<input
													style="cursor: pointer" type=button
													onclick="hideDivControl('shareControl')"
													value="<c:out value='${context.button_cancel}' />"></td>
											</tr>
										</table>
										</FORM>
										</td>
									</tr>





								</table>
								</div>


								</td>
							</tr>
						</table>
						</div>

						</TD>
						<td width=270 nowrap valign=top><c:import
							url="/group/messagedetail_related.jsp" /></td>
					</TR>
				</table>
				</td>
			</tr>
		</table>
		</td>
	</tr>



	<tr>
		<td><BR>
		<BR>
		<c:import url="/footer.jsp" /></td>
	</tr>


</table>

<c:if test="${not empty msg}">
	<script>alert('${msg }')</script>
</c:if>
<script>
<c:if test="${param.init=='reply'&& not empty session_user}">form1.content.focus(); </c:if>

</script>
</body>
</html>

